import { useDataViewStore } from "@/stores/dataview"
import { computed } from "vue"

export const useTargetData = ()=>{
    const dataView = useDataViewStore()
    const targetData = computed(()=>{
        const list = dataView.getComponentList
        const targetIndex = dataView.fetchTargetIndex()
        return list[targetIndex]
    })
    return {
        targetData,
        dataView
    }
}